{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "import lasio"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "lasio will automatically try and import pandas"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [],
   "source": [
    "import os\n",
    "l = lasio.read(os.path.join(\"..\", \"tests\", \"examples\", \"6038187_v1.2.las\"))"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "If [pandas](http://pandas.pydata.org/) is installed, you can use the df() method to get a pandas [DataFrame](http://pandas.pydata.org/pandas-docs/stable/dsintro.html#dataframe) version of the data section:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 3,
   "metadata": {},
   "outputs": [],
   "source": [
    "df = l.df()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "pandas.core.frame.DataFrame"
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "type(df)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "View a snapshot of the dataframe with the `head()` method, which takes number of lines as an argument:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style>\n",
       "    .dataframe thead tr:only-child th {\n",
       "        text-align: right;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: left;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>CALI</th>\n",
       "      <th>DFAR</th>\n",
       "      <th>DNEAR</th>\n",
       "      <th>GAMN</th>\n",
       "      <th>NEUT</th>\n",
       "      <th>PR</th>\n",
       "      <th>SP</th>\n",
       "      <th>COND</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>DEPT</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0.05</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0.10</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>NaN</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>-116.998</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0.15</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>NaN</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>-116.998</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0.20</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>NaN</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>-116.998</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0.25</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>NaN</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>-116.998</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0.30</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>NaN</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>-116.998</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0.35</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>NaN</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>-116.998</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0.40</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>NaN</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>-116.998</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0.45</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>NaN</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>-116.998</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>0.50</th>\n",
       "      <td>49.765</td>\n",
       "      <td>4.587</td>\n",
       "      <td>3.382</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>NaN</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>-116.998</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "        CALI   DFAR  DNEAR     GAMN  NEUT       PR     SP     COND\n",
       "DEPT                                                              \n",
       "0.05  49.765  4.587  3.382      NaN   NaN      NaN    NaN      NaN\n",
       "0.10  49.765  4.587  3.382 -2324.28   NaN  115.508 -3.049 -116.998\n",
       "0.15  49.765  4.587  3.382 -2324.28   NaN  115.508 -3.049 -116.998\n",
       "0.20  49.765  4.587  3.382 -2324.28   NaN  115.508 -3.049 -116.998\n",
       "0.25  49.765  4.587  3.382 -2324.28   NaN  115.508 -3.049 -116.998\n",
       "0.30  49.765  4.587  3.382 -2324.28   NaN  115.508 -3.049 -116.998\n",
       "0.35  49.765  4.587  3.382 -2324.28   NaN  115.508 -3.049 -116.998\n",
       "0.40  49.765  4.587  3.382 -2324.28   NaN  115.508 -3.049 -116.998\n",
       "0.45  49.765  4.587  3.382 -2324.28   NaN  115.508 -3.049 -116.998\n",
       "0.50  49.765  4.587  3.382 -2324.28   NaN  115.508 -3.049 -116.998"
      ]
     },
     "execution_count": 5,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.head(10)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Or look at the data at the bottom of the hole with the similar method ``tail()``:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style>\n",
       "    .dataframe thead tr:only-child th {\n",
       "        text-align: right;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: left;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>CALI</th>\n",
       "      <th>DFAR</th>\n",
       "      <th>DNEAR</th>\n",
       "      <th>GAMN</th>\n",
       "      <th>NEUT</th>\n",
       "      <th>PR</th>\n",
       "      <th>SP</th>\n",
       "      <th>COND</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>DEPT</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>134.15</th>\n",
       "      <td>101.408</td>\n",
       "      <td>1.628</td>\n",
       "      <td>1.404</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>128.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>581.113</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.20</th>\n",
       "      <td>101.402</td>\n",
       "      <td>1.576</td>\n",
       "      <td>1.411</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>158.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>580.619</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.25</th>\n",
       "      <td>101.336</td>\n",
       "      <td>1.609</td>\n",
       "      <td>1.405</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>131.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>584.571</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.30</th>\n",
       "      <td>101.330</td>\n",
       "      <td>1.596</td>\n",
       "      <td>1.418</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>149.994</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>594.695</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.35</th>\n",
       "      <td>101.336</td>\n",
       "      <td>1.630</td>\n",
       "      <td>1.417</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>139.003</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>601.612</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.40</th>\n",
       "      <td>101.330</td>\n",
       "      <td>1.616</td>\n",
       "      <td>1.418</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>160.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>607.295</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.45</th>\n",
       "      <td>101.313</td>\n",
       "      <td>1.615</td>\n",
       "      <td>1.444</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>129.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>608.777</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.50</th>\n",
       "      <td>101.301</td>\n",
       "      <td>1.577</td>\n",
       "      <td>1.383</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>171.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>603.343</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.55</th>\n",
       "      <td>101.289</td>\n",
       "      <td>1.600</td>\n",
       "      <td>1.368</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>138.010</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>594.948</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.60</th>\n",
       "      <td>101.037</td>\n",
       "      <td>1.555</td>\n",
       "      <td>1.395</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>165.991</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>584.327</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.65</th>\n",
       "      <td>100.983</td>\n",
       "      <td>1.563</td>\n",
       "      <td>1.357</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>158.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>578.643</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.70</th>\n",
       "      <td>100.833</td>\n",
       "      <td>1.570</td>\n",
       "      <td>1.357</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>571.233</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.75</th>\n",
       "      <td>93.760</td>\n",
       "      <td>1.582</td>\n",
       "      <td>1.378</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>565.552</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.80</th>\n",
       "      <td>88.086</td>\n",
       "      <td>1.561</td>\n",
       "      <td>1.361</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>570.490</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.85</th>\n",
       "      <td>86.443</td>\n",
       "      <td>1.516</td>\n",
       "      <td>1.338</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>574.937</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.90</th>\n",
       "      <td>79.617</td>\n",
       "      <td>5.989</td>\n",
       "      <td>1.356</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>579.137</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>134.95</th>\n",
       "      <td>65.236</td>\n",
       "      <td>4.587</td>\n",
       "      <td>1.397</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.00</th>\n",
       "      <td>55.833</td>\n",
       "      <td>4.587</td>\n",
       "      <td>1.351</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.05</th>\n",
       "      <td>49.061</td>\n",
       "      <td>4.587</td>\n",
       "      <td>1.329</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.10</th>\n",
       "      <td>49.036</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.15</th>\n",
       "      <td>49.024</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.20</th>\n",
       "      <td>49.005</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.25</th>\n",
       "      <td>48.999</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.30</th>\n",
       "      <td>48.987</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.35</th>\n",
       "      <td>48.980</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.40</th>\n",
       "      <td>48.962</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.45</th>\n",
       "      <td>48.962</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.50</th>\n",
       "      <td>48.925</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.55</th>\n",
       "      <td>48.931</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.60</th>\n",
       "      <td>48.919</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.65</th>\n",
       "      <td>48.900</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.70</th>\n",
       "      <td>48.882</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.75</th>\n",
       "      <td>48.863</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.80</th>\n",
       "      <td>48.857</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.85</th>\n",
       "      <td>48.839</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.90</th>\n",
       "      <td>48.808</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>135.95</th>\n",
       "      <td>48.802</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.00</th>\n",
       "      <td>48.789</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.05</th>\n",
       "      <td>48.771</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.10</th>\n",
       "      <td>48.765</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.15</th>\n",
       "      <td>48.752</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.20</th>\n",
       "      <td>48.734</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.25</th>\n",
       "      <td>48.684</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.30</th>\n",
       "      <td>48.666</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.35</th>\n",
       "      <td>48.647</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.40</th>\n",
       "      <td>48.604</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.45</th>\n",
       "      <td>48.555</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.50</th>\n",
       "      <td>48.555</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.55</th>\n",
       "      <td>48.438</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.60</th>\n",
       "      <td>-56.275</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "           CALI   DFAR  DNEAR     GAMN     NEUT       PR     SP     COND\n",
       "DEPT                                                                    \n",
       "134.15  101.408  1.628  1.404 -2324.28  128.000  115.508 -3.049  581.113\n",
       "134.20  101.402  1.576  1.411 -2324.28  158.000  115.508 -3.049  580.619\n",
       "134.25  101.336  1.609  1.405 -2324.28  131.000  115.508 -3.049  584.571\n",
       "134.30  101.330  1.596  1.418 -2324.28  149.994  115.508 -3.049  594.695\n",
       "134.35  101.336  1.630  1.417 -2324.28  139.003  115.508 -3.049  601.612\n",
       "134.40  101.330  1.616  1.418 -2324.28  160.000  115.508 -3.049  607.295\n",
       "134.45  101.313  1.615  1.444 -2324.28  129.000  115.508 -3.049  608.777\n",
       "134.50  101.301  1.577  1.383 -2324.28  171.000  115.508 -3.049  603.343\n",
       "134.55  101.289  1.600  1.368 -2324.28  138.010  115.508 -3.049  594.948\n",
       "134.60  101.037  1.555  1.395 -2324.28  165.991  115.508 -3.049  584.327\n",
       "134.65  100.983  1.563  1.357 -2324.28  158.000  115.508 -3.049  578.643\n",
       "134.70  100.833  1.570  1.357      NaN      NaN      NaN    NaN  571.233\n",
       "134.75   93.760  1.582  1.378      NaN      NaN      NaN    NaN  565.552\n",
       "134.80   88.086  1.561  1.361      NaN      NaN      NaN    NaN  570.490\n",
       "134.85   86.443  1.516  1.338      NaN      NaN      NaN    NaN  574.937\n",
       "134.90   79.617  5.989  1.356      NaN      NaN      NaN    NaN  579.137\n",
       "134.95   65.236  4.587  1.397      NaN      NaN      NaN    NaN      NaN\n",
       "135.00   55.833  4.587  1.351      NaN      NaN      NaN    NaN      NaN\n",
       "135.05   49.061  4.587  1.329      NaN      NaN      NaN    NaN      NaN\n",
       "135.10   49.036    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.15   49.024    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.20   49.005    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.25   48.999    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.30   48.987    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.35   48.980    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.40   48.962    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.45   48.962    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.50   48.925    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.55   48.931    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.60   48.919    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.65   48.900    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.70   48.882    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.75   48.863    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.80   48.857    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.85   48.839    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.90   48.808    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "135.95   48.802    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.00   48.789    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.05   48.771    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.10   48.765    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.15   48.752    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.20   48.734    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.25   48.684    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.30   48.666    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.35   48.647    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.40   48.604    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.45   48.555    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.50   48.555    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.55   48.438    NaN    NaN      NaN      NaN      NaN    NaN      NaN\n",
       "136.60  -56.275    NaN    NaN      NaN      NaN      NaN    NaN      NaN"
      ]
     },
     "execution_count": 6,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.tail(50)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Use the `describe()` method to return basic statistical information about the curves in the dataframe:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style>\n",
       "    .dataframe thead tr:only-child th {\n",
       "        text-align: right;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: left;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>CALI</th>\n",
       "      <th>DFAR</th>\n",
       "      <th>DNEAR</th>\n",
       "      <th>GAMN</th>\n",
       "      <th>NEUT</th>\n",
       "      <th>PR</th>\n",
       "      <th>SP</th>\n",
       "      <th>COND</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>count</th>\n",
       "      <td>2732.000000</td>\n",
       "      <td>2701.000000</td>\n",
       "      <td>2701.000000</td>\n",
       "      <td>2691.000000</td>\n",
       "      <td>2492.000000</td>\n",
       "      <td>2692.000000</td>\n",
       "      <td>2692.000000</td>\n",
       "      <td>2697.000000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>mean</th>\n",
       "      <td>97.432002</td>\n",
       "      <td>1.767922</td>\n",
       "      <td>1.729209</td>\n",
       "      <td>-102.330033</td>\n",
       "      <td>441.600013</td>\n",
       "      <td>17940.522307</td>\n",
       "      <td>90.393464</td>\n",
       "      <td>478.670791</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>std</th>\n",
       "      <td>13.939547</td>\n",
       "      <td>0.480333</td>\n",
       "      <td>0.372412</td>\n",
       "      <td>630.106420</td>\n",
       "      <td>370.138208</td>\n",
       "      <td>22089.297212</td>\n",
       "      <td>26.725547</td>\n",
       "      <td>753.869866</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>min</th>\n",
       "      <td>-56.275000</td>\n",
       "      <td>0.725000</td>\n",
       "      <td>0.657001</td>\n",
       "      <td>-2324.280000</td>\n",
       "      <td>81.001800</td>\n",
       "      <td>115.508000</td>\n",
       "      <td>-3.049000</td>\n",
       "      <td>-116.998000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>25%</th>\n",
       "      <td>101.077500</td>\n",
       "      <td>1.526000</td>\n",
       "      <td>1.535000</td>\n",
       "      <td>55.783000</td>\n",
       "      <td>158.002000</td>\n",
       "      <td>2652.470000</td>\n",
       "      <td>93.495500</td>\n",
       "      <td>200.981000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>50%</th>\n",
       "      <td>101.426000</td>\n",
       "      <td>1.758000</td>\n",
       "      <td>1.785000</td>\n",
       "      <td>74.376900</td>\n",
       "      <td>256.501500</td>\n",
       "      <td>2709.345000</td>\n",
       "      <td>99.994000</td>\n",
       "      <td>266.435000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>75%</th>\n",
       "      <td>101.582000</td>\n",
       "      <td>1.993000</td>\n",
       "      <td>1.948000</td>\n",
       "      <td>88.326900</td>\n",
       "      <td>680.500250</td>\n",
       "      <td>50499.900000</td>\n",
       "      <td>100.623000</td>\n",
       "      <td>505.530000</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>max</th>\n",
       "      <td>103.380000</td>\n",
       "      <td>5.989000</td>\n",
       "      <td>3.382000</td>\n",
       "      <td>169.672000</td>\n",
       "      <td>1665.990000</td>\n",
       "      <td>50499.900000</td>\n",
       "      <td>102.902000</td>\n",
       "      <td>4978.160000</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "              CALI         DFAR        DNEAR         GAMN         NEUT  \\\n",
       "count  2732.000000  2701.000000  2701.000000  2691.000000  2492.000000   \n",
       "mean     97.432002     1.767922     1.729209  -102.330033   441.600013   \n",
       "std      13.939547     0.480333     0.372412   630.106420   370.138208   \n",
       "min     -56.275000     0.725000     0.657001 -2324.280000    81.001800   \n",
       "25%     101.077500     1.526000     1.535000    55.783000   158.002000   \n",
       "50%     101.426000     1.758000     1.785000    74.376900   256.501500   \n",
       "75%     101.582000     1.993000     1.948000    88.326900   680.500250   \n",
       "max     103.380000     5.989000     3.382000   169.672000  1665.990000   \n",
       "\n",
       "                 PR           SP         COND  \n",
       "count   2692.000000  2692.000000  2697.000000  \n",
       "mean   17940.522307    90.393464   478.670791  \n",
       "std    22089.297212    26.725547   753.869866  \n",
       "min      115.508000    -3.049000  -116.998000  \n",
       "25%     2652.470000    93.495500   200.981000  \n",
       "50%     2709.345000    99.994000   266.435000  \n",
       "75%    50499.900000   100.623000   505.530000  \n",
       "max    50499.900000   102.902000  4978.160000  "
      ]
     },
     "execution_count": 7,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.describe()"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Calculations are easy in a dataframe.  As a simple example, let's convert conductivity to resistivity:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [],
   "source": [
    "df['RES'] = 1000 / df.COND"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style>\n",
       "    .dataframe thead tr:only-child th {\n",
       "        text-align: right;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: left;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>CALI</th>\n",
       "      <th>DFAR</th>\n",
       "      <th>DNEAR</th>\n",
       "      <th>GAMN</th>\n",
       "      <th>NEUT</th>\n",
       "      <th>PR</th>\n",
       "      <th>SP</th>\n",
       "      <th>COND</th>\n",
       "      <th>RES</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>DEPT</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>100.00</th>\n",
       "      <td>101.546</td>\n",
       "      <td>1.955</td>\n",
       "      <td>1.876</td>\n",
       "      <td>127.8290</td>\n",
       "      <td>237.997</td>\n",
       "      <td>2655.37</td>\n",
       "      <td>92.957</td>\n",
       "      <td>318.800</td>\n",
       "      <td>3.136763</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.05</th>\n",
       "      <td>101.540</td>\n",
       "      <td>1.988</td>\n",
       "      <td>1.919</td>\n",
       "      <td>90.6593</td>\n",
       "      <td>237.000</td>\n",
       "      <td>2662.04</td>\n",
       "      <td>92.926</td>\n",
       "      <td>311.391</td>\n",
       "      <td>3.211397</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.10</th>\n",
       "      <td>101.516</td>\n",
       "      <td>1.986</td>\n",
       "      <td>1.911</td>\n",
       "      <td>83.6761</td>\n",
       "      <td>243.999</td>\n",
       "      <td>2651.62</td>\n",
       "      <td>92.926</td>\n",
       "      <td>306.697</td>\n",
       "      <td>3.260547</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.15</th>\n",
       "      <td>101.504</td>\n",
       "      <td>2.010</td>\n",
       "      <td>1.904</td>\n",
       "      <td>109.2380</td>\n",
       "      <td>237.001</td>\n",
       "      <td>2660.50</td>\n",
       "      <td>92.938</td>\n",
       "      <td>301.263</td>\n",
       "      <td>3.319359</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.20</th>\n",
       "      <td>101.474</td>\n",
       "      <td>1.993</td>\n",
       "      <td>1.897</td>\n",
       "      <td>92.9720</td>\n",
       "      <td>191.000</td>\n",
       "      <td>2657.42</td>\n",
       "      <td>92.969</td>\n",
       "      <td>297.804</td>\n",
       "      <td>3.357913</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.25</th>\n",
       "      <td>101.408</td>\n",
       "      <td>2.013</td>\n",
       "      <td>1.909</td>\n",
       "      <td>88.3237</td>\n",
       "      <td>240.992</td>\n",
       "      <td>2656.74</td>\n",
       "      <td>92.953</td>\n",
       "      <td>298.051</td>\n",
       "      <td>3.355130</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.30</th>\n",
       "      <td>101.438</td>\n",
       "      <td>2.033</td>\n",
       "      <td>1.874</td>\n",
       "      <td>125.5010</td>\n",
       "      <td>218.007</td>\n",
       "      <td>2658.62</td>\n",
       "      <td>92.957</td>\n",
       "      <td>298.792</td>\n",
       "      <td>3.346810</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.35</th>\n",
       "      <td>101.486</td>\n",
       "      <td>1.965</td>\n",
       "      <td>1.908</td>\n",
       "      <td>90.6533</td>\n",
       "      <td>244.996</td>\n",
       "      <td>2663.92</td>\n",
       "      <td>92.975</td>\n",
       "      <td>304.966</td>\n",
       "      <td>3.279054</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.40</th>\n",
       "      <td>101.528</td>\n",
       "      <td>2.039</td>\n",
       "      <td>1.938</td>\n",
       "      <td>95.2953</td>\n",
       "      <td>207.006</td>\n",
       "      <td>2666.49</td>\n",
       "      <td>92.984</td>\n",
       "      <td>311.141</td>\n",
       "      <td>3.213977</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.45</th>\n",
       "      <td>101.564</td>\n",
       "      <td>2.021</td>\n",
       "      <td>1.947</td>\n",
       "      <td>74.3780</td>\n",
       "      <td>189.000</td>\n",
       "      <td>2665.46</td>\n",
       "      <td>93.005</td>\n",
       "      <td>318.305</td>\n",
       "      <td>3.141641</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>100.50</th>\n",
       "      <td>101.600</td>\n",
       "      <td>2.027</td>\n",
       "      <td>1.948</td>\n",
       "      <td>72.0534</td>\n",
       "      <td>199.998</td>\n",
       "      <td>2664.09</td>\n",
       "      <td>93.011</td>\n",
       "      <td>328.430</td>\n",
       "      <td>3.044789</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "           CALI   DFAR  DNEAR      GAMN     NEUT       PR      SP     COND  \\\n",
       "DEPT                                                                         \n",
       "100.00  101.546  1.955  1.876  127.8290  237.997  2655.37  92.957  318.800   \n",
       "100.05  101.540  1.988  1.919   90.6593  237.000  2662.04  92.926  311.391   \n",
       "100.10  101.516  1.986  1.911   83.6761  243.999  2651.62  92.926  306.697   \n",
       "100.15  101.504  2.010  1.904  109.2380  237.001  2660.50  92.938  301.263   \n",
       "100.20  101.474  1.993  1.897   92.9720  191.000  2657.42  92.969  297.804   \n",
       "100.25  101.408  2.013  1.909   88.3237  240.992  2656.74  92.953  298.051   \n",
       "100.30  101.438  2.033  1.874  125.5010  218.007  2658.62  92.957  298.792   \n",
       "100.35  101.486  1.965  1.908   90.6533  244.996  2663.92  92.975  304.966   \n",
       "100.40  101.528  2.039  1.938   95.2953  207.006  2666.49  92.984  311.141   \n",
       "100.45  101.564  2.021  1.947   74.3780  189.000  2665.46  93.005  318.305   \n",
       "100.50  101.600  2.027  1.948   72.0534  199.998  2664.09  93.011  328.430   \n",
       "\n",
       "             RES  \n",
       "DEPT              \n",
       "100.00  3.136763  \n",
       "100.05  3.211397  \n",
       "100.10  3.260547  \n",
       "100.15  3.319359  \n",
       "100.20  3.357913  \n",
       "100.25  3.355130  \n",
       "100.30  3.346810  \n",
       "100.35  3.279054  \n",
       "100.40  3.213977  \n",
       "100.45  3.141641  \n",
       "100.50  3.044789  "
      ]
     },
     "execution_count": 9,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df[100:100.5]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Convert the depth index to feet:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [],
   "source": [
    "df.index = df.index / 0.3048"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Note that now the units of the indices used on the DataFrame are in feet, and it uses the nearest existing value:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style>\n",
       "    .dataframe thead tr:only-child th {\n",
       "        text-align: right;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: left;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>CALI</th>\n",
       "      <th>DFAR</th>\n",
       "      <th>DNEAR</th>\n",
       "      <th>GAMN</th>\n",
       "      <th>NEUT</th>\n",
       "      <th>PR</th>\n",
       "      <th>SP</th>\n",
       "      <th>COND</th>\n",
       "      <th>RES</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>DEPT</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>441.108924</th>\n",
       "      <td>101.313</td>\n",
       "      <td>1.615</td>\n",
       "      <td>1.444</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>129.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>608.777</td>\n",
       "      <td>1.642638</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>441.272966</th>\n",
       "      <td>101.301</td>\n",
       "      <td>1.577</td>\n",
       "      <td>1.383</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>171.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>603.343</td>\n",
       "      <td>1.657432</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>441.437008</th>\n",
       "      <td>101.289</td>\n",
       "      <td>1.600</td>\n",
       "      <td>1.368</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>138.010</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>594.948</td>\n",
       "      <td>1.680819</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>441.601050</th>\n",
       "      <td>101.037</td>\n",
       "      <td>1.555</td>\n",
       "      <td>1.395</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>165.991</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>584.327</td>\n",
       "      <td>1.711371</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>441.765092</th>\n",
       "      <td>100.983</td>\n",
       "      <td>1.563</td>\n",
       "      <td>1.357</td>\n",
       "      <td>-2324.28</td>\n",
       "      <td>158.000</td>\n",
       "      <td>115.508</td>\n",
       "      <td>-3.049</td>\n",
       "      <td>578.643</td>\n",
       "      <td>1.728181</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>441.929134</th>\n",
       "      <td>100.833</td>\n",
       "      <td>1.570</td>\n",
       "      <td>1.357</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>571.233</td>\n",
       "      <td>1.750599</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>442.093176</th>\n",
       "      <td>93.760</td>\n",
       "      <td>1.582</td>\n",
       "      <td>1.378</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>565.552</td>\n",
       "      <td>1.768184</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>442.257218</th>\n",
       "      <td>88.086</td>\n",
       "      <td>1.561</td>\n",
       "      <td>1.361</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>570.490</td>\n",
       "      <td>1.752879</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>442.421260</th>\n",
       "      <td>86.443</td>\n",
       "      <td>1.516</td>\n",
       "      <td>1.338</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>574.937</td>\n",
       "      <td>1.739321</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>442.585302</th>\n",
       "      <td>79.617</td>\n",
       "      <td>5.989</td>\n",
       "      <td>1.356</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>579.137</td>\n",
       "      <td>1.726707</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>442.749344</th>\n",
       "      <td>65.236</td>\n",
       "      <td>4.587</td>\n",
       "      <td>1.397</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>442.913386</th>\n",
       "      <td>55.833</td>\n",
       "      <td>4.587</td>\n",
       "      <td>1.351</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>443.077428</th>\n",
       "      <td>49.061</td>\n",
       "      <td>4.587</td>\n",
       "      <td>1.329</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>443.241470</th>\n",
       "      <td>49.036</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>443.405512</th>\n",
       "      <td>49.024</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>443.569554</th>\n",
       "      <td>49.005</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>443.733596</th>\n",
       "      <td>48.999</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>443.897638</th>\n",
       "      <td>48.987</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>444.061680</th>\n",
       "      <td>48.980</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>444.225722</th>\n",
       "      <td>48.962</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>444.389764</th>\n",
       "      <td>48.962</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>444.553806</th>\n",
       "      <td>48.925</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>444.717848</th>\n",
       "      <td>48.931</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>444.881890</th>\n",
       "      <td>48.919</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>445.045932</th>\n",
       "      <td>48.900</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>445.209974</th>\n",
       "      <td>48.882</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>445.374016</th>\n",
       "      <td>48.863</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>445.538058</th>\n",
       "      <td>48.857</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>445.702100</th>\n",
       "      <td>48.839</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>445.866142</th>\n",
       "      <td>48.808</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "               CALI   DFAR  DNEAR     GAMN     NEUT       PR     SP     COND  \\\n",
       "DEPT                                                                           \n",
       "441.108924  101.313  1.615  1.444 -2324.28  129.000  115.508 -3.049  608.777   \n",
       "441.272966  101.301  1.577  1.383 -2324.28  171.000  115.508 -3.049  603.343   \n",
       "441.437008  101.289  1.600  1.368 -2324.28  138.010  115.508 -3.049  594.948   \n",
       "441.601050  101.037  1.555  1.395 -2324.28  165.991  115.508 -3.049  584.327   \n",
       "441.765092  100.983  1.563  1.357 -2324.28  158.000  115.508 -3.049  578.643   \n",
       "441.929134  100.833  1.570  1.357      NaN      NaN      NaN    NaN  571.233   \n",
       "442.093176   93.760  1.582  1.378      NaN      NaN      NaN    NaN  565.552   \n",
       "442.257218   88.086  1.561  1.361      NaN      NaN      NaN    NaN  570.490   \n",
       "442.421260   86.443  1.516  1.338      NaN      NaN      NaN    NaN  574.937   \n",
       "442.585302   79.617  5.989  1.356      NaN      NaN      NaN    NaN  579.137   \n",
       "442.749344   65.236  4.587  1.397      NaN      NaN      NaN    NaN      NaN   \n",
       "442.913386   55.833  4.587  1.351      NaN      NaN      NaN    NaN      NaN   \n",
       "443.077428   49.061  4.587  1.329      NaN      NaN      NaN    NaN      NaN   \n",
       "443.241470   49.036    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "443.405512   49.024    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "443.569554   49.005    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "443.733596   48.999    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "443.897638   48.987    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "444.061680   48.980    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "444.225722   48.962    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "444.389764   48.962    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "444.553806   48.925    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "444.717848   48.931    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "444.881890   48.919    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "445.045932   48.900    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "445.209974   48.882    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "445.374016   48.863    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "445.538058   48.857    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "445.702100   48.839    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "445.866142   48.808    NaN    NaN      NaN      NaN      NaN    NaN      NaN   \n",
       "\n",
       "                 RES  \n",
       "DEPT                  \n",
       "441.108924  1.642638  \n",
       "441.272966  1.657432  \n",
       "441.437008  1.680819  \n",
       "441.601050  1.711371  \n",
       "441.765092  1.728181  \n",
       "441.929134  1.750599  \n",
       "442.093176  1.768184  \n",
       "442.257218  1.752879  \n",
       "442.421260  1.739321  \n",
       "442.585302  1.726707  \n",
       "442.749344       NaN  \n",
       "442.913386       NaN  \n",
       "443.077428       NaN  \n",
       "443.241470       NaN  \n",
       "443.405512       NaN  \n",
       "443.569554       NaN  \n",
       "443.733596       NaN  \n",
       "443.897638       NaN  \n",
       "444.061680       NaN  \n",
       "444.225722       NaN  \n",
       "444.389764       NaN  \n",
       "444.553806       NaN  \n",
       "444.717848       NaN  \n",
       "444.881890       NaN  \n",
       "445.045932       NaN  \n",
       "445.209974       NaN  \n",
       "445.374016       NaN  \n",
       "445.538058       NaN  \n",
       "445.702100       NaN  \n",
       "445.866142       NaN  "
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df[441:446]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true
   },
   "source": [
    "convert back to metres:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": [
    "df.index *= 0.3048"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "and this time let's ask just for the last 10 samples in the file, using the [``iloc`` attribute](http://pandas.pydata.org/pandas-docs/version/0.17.1/generated/pandas.DataFrame.iloc.html)"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style>\n",
       "    .dataframe thead tr:only-child th {\n",
       "        text-align: right;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: left;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>CALI</th>\n",
       "      <th>DFAR</th>\n",
       "      <th>DNEAR</th>\n",
       "      <th>GAMN</th>\n",
       "      <th>NEUT</th>\n",
       "      <th>PR</th>\n",
       "      <th>SP</th>\n",
       "      <th>COND</th>\n",
       "      <th>RES</th>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>DEPT</th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "      <th></th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>136.15</th>\n",
       "      <td>48.752</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.20</th>\n",
       "      <td>48.734</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.25</th>\n",
       "      <td>48.684</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.30</th>\n",
       "      <td>48.666</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.35</th>\n",
       "      <td>48.647</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.40</th>\n",
       "      <td>48.604</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.45</th>\n",
       "      <td>48.555</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.50</th>\n",
       "      <td>48.555</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.55</th>\n",
       "      <td>48.438</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>136.60</th>\n",
       "      <td>-56.275</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "      <td>NaN</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "          CALI  DFAR  DNEAR  GAMN  NEUT  PR  SP  COND  RES\n",
       "DEPT                                                      \n",
       "136.15  48.752   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN\n",
       "136.20  48.734   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN\n",
       "136.25  48.684   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN\n",
       "136.30  48.666   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN\n",
       "136.35  48.647   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN\n",
       "136.40  48.604   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN\n",
       "136.45  48.555   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN\n",
       "136.50  48.555   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN\n",
       "136.55  48.438   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN\n",
       "136.60 -56.275   NaN    NaN   NaN   NaN NaN NaN   NaN  NaN"
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.iloc[-10:]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 18,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "CALI     48.555\n",
       "DFAR        NaN\n",
       "DNEAR       NaN\n",
       "GAMN        NaN\n",
       "NEUT        NaN\n",
       "PR          NaN\n",
       "SP          NaN\n",
       "COND        NaN\n",
       "RES         NaN\n",
       "Name: 136.45, dtype: float64"
      ]
     },
     "execution_count": 18,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.loc[136.45]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 19,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "CALI     48.555\n",
       "DFAR        NaN\n",
       "DNEAR       NaN\n",
       "GAMN        NaN\n",
       "NEUT        NaN\n",
       "PR          NaN\n",
       "SP          NaN\n",
       "COND        NaN\n",
       "RES         NaN\n",
       "Name: 136.45, dtype: float64"
      ]
     },
     "execution_count": 19,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "df.iloc[-4]"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {
    "collapsed": true
   },
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.5.3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 1
}
